import { baseUrl, http } from "..";

const api = http('ecard')

/**
 * 获取名片用户信息
 * @param {Object} searcher 查询条件
 * @param {Number} settingId 配置项id
 * @param {Number} page 页码
 * @param {Number} size 页面容量
 */
export const getECardUserInfoList = (searcher, settingId, page = 1, size = 30) => {
	return api({
		url: `/api/ecard/users/${settingId}/${page}/${size}`,
		method: 'post',
		data: searcher
	})
}

/**
 * 获取用户的配置信息
 * @param {String} userId 
 */
export const getUserSettings = (userId) => {
	return api({
		url: `/api/ecard/user-settings/${userId}`,
	})
}

/**
 * 获取配置的所有用户信息
 */
export const getECardUsers = (settingId) => {
	return api({
		url: `/api/ecard/users/${settingId}`
	})
}
